import 'package:flutter/cupertino.dart';
import 'package:flutter/material.dart';

main(){
  runApp(MyApp());
}
class MyApp extends StatelessWidget{
  @override
  Widget build(BuildContext context) {
    // TODO: implement build
    return MaterialApp(
      theme: ThemeData(
        primarySwatch: Colors.blue
      ),
      home: Scaffold(
        appBar: AppBar(
          backgroundColor: Color.fromRGBO(51, 51, 51, 1),
          titleSpacing: 0.0,
          title:Row(
            mainAxisAlignment: MainAxisAlignment.spaceBetween,
            children: [
              FlatButton(
                materialTapTargetSize: MaterialTapTargetSize.shrinkWrap,
                child: Row(
                  children: [
                    Icon(Icons.arrow_back_ios,color: Colors.white,),
                    Text('返回',style: TextStyle(color: Colors.white,fontSize: 16),)
                  ],
                ),
                onPressed: (){},
              ),
              Container(child: Row(children: [
                Text('附近任务',style: TextStyle(fontSize: 16),),
                SizedBox(width: 25,)
              ],),),
              IconButton(icon: Icon(Icons.more_horiz), onPressed: (){})
            ],
          )
        ),
        body: Container(
          child: DefaultTabController(
            length: 2,
            child: TabBar(
              tabs: [
                Tab(
                 text: 'asdasd',
                ),
                Tab(
                  text: 'asdasd',
                ),
              ],
            ),
          ),
        ),
      ),
    );
  }
}